<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>For Loop</title>
</head>
<body>

<script>
    var x;
    var nums = [1, 3, 5];
    for (x in nums)
    {
        document.write(x+ "<br />");
    }

    let iterable = [10, 20, 30];

    for (let value of iterable) {
        console.log(value);
    }
</script>

</body>
</html>